export default {
  // input enter后收起键盘
  enterBlur(el) {
    let goal = null;
    if (el.tagName.toLocaleLowerCase() == 'input') {
      goal = el;
    } else {
      const arr = el.getElementsByTagName('input');
      if (!arr.length) return;
      goal = arr[0];
    }
    // const func = goal.onkeyup;
    goal.onkeyup = function (e) {
      if (e.keyCode == 13) {
        goal.blur();
      }
    };
  }
};